Skip to content

Conversation

@BenjaminHerbert
Copy link

Changes

This is work in progress.

Allows to ignore volumes.

Closes #1078

Submitter Checklist

These are the criteria that every PR should meet, please check them off as you
review them:

See the contribution guide for more details.

@BenjaminHerbert
Copy link
Author

If this is going in the right direction, I can complete the other entries discussed in #1078.

  • IgnoredAnnotations
  • IgnoredEnvVars
  • IgnoredLabels

@BenjaminHerbert
Copy link
Author

Not sure if there is a notification about a draft. Could you give me a feedback, if this goes into the right direction, @brokenpip3?

@brokenpip3
Copy link
Collaborator

Not sure if there is a notification about a draft. Could you give me a feedback, if this goes into the right direction, @brokenpip3?

yes sorry, will take a look asap!

@brokenpip3
Copy link
Collaborator

brokenpip3 commented May 12, 2025

Sorry if took me a while, the PR looks good as start, we can continue like this for the others :)
However f possible let's not add directly IgnoredVolumes or IgnoredXXXX but a more comprehensive struct like:

type JenkinsSpec struct {
	[...]
	Lifecycle JenkinsLifecycle `json:"lifecycle,omitempty"`
}

type JenkinsLifecycle struct {
	Ignore JenkinsLifecycleIgnore `json:"ignore,omitempty"`
}

type JenkinsLifecycleIgnore struct {
	IgnoredVolumes []string `json:"volumes,omitempty"`
	IgnoredEnvs []string `json:"envs,omitempty"`
	IgnoredAnnotations []string `annotations:"envs,omitempty"`
	IgnoredLabels []string `json:"labels,omitempty"`
}

so we can express it like that:

kind: Jenkins
metadata:
  name: example
spec:
  lifecycle:
    ignore:
      volumes:
        - /var/lib/jenkins/cache
        - /var/lib/jenkins/tmp
      envs:
       - FOOBAR

you can continue to adjust the unit tests and I can instead add the e2e tests for cover your changes, don't worry about that part, it's something I can complete.

thanks again for your contribution!

It allows to specify ignores values.

Note that additional values are ignored anyways, this ignore annotation only handles different values or additional annotations.
@BenjaminHerbert
Copy link
Author

I have adapted your changes and implemented ignoring of annotations and volumes.

@brokenpip3 brokenpip3 marked this pull request as ready for review May 23, 2025 22:02
@brokenpip3 brokenpip3 self-requested a review as a code owner May 23, 2025 22:02
@github-actions github-actions bot added the stale label Sep 17, 2025
@github-actions github-actions bot closed this Sep 24, 2025
@brokenpip3 brokenpip3 reopened this Sep 24, 2025
@github-actions github-actions bot removed the stale label Sep 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow projected volumes / Allow certain volumes - Support Azure Workload Identity

2 participants